-
Notifications
You must be signed in to change notification settings - Fork 214
fix: many null checks fixed #2059
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
LukasDeco
added a commit
that referenced
this pull request
Jan 6, 2026
* fix: many null checks fixed * fix: prettier * feat: get active markets helpers * fix: prettier
lowkeynicc
pushed a commit
that referenced
this pull request
Jan 6, 2026
LukasDeco
added a commit
that referenced
this pull request
Jan 6, 2026
* fix: many null checks fixed * fix: prettier * feat: get active markets helpers * fix: prettier
LukasDeco
added a commit
that referenced
this pull request
Jan 15, 2026
* program: make lp shares reduce only * init * rm more fields * make tests build * start sdk changes * init new margin calc * deposit and transfer into * add settle pnl * program: add withdraw * add more ix * add new meets withdraw req fn * enter/exit liquidation logic * moar * start liquidation logic * other liquidation fns * make build work * more updates * always calc isolated pos * rm isolated position market index logic * moar * program: rm the isolated position market index * some tweaks * rm some old margin code * tweak meets withdraw requirements * rm liquidation mode changing context * handle liquidation id and bit flags * more liquidation changes * clean * fix force cancel orders * update validate liquidation * moar * rename is_being_liquidated * start adding test * program: add validate for liq borrow for perp pnl * program: add test for isolated margin calc * is bankrupt test * fix cancel orders * fix set liquidation status * more tweaks * clean up naming * update last active slot for isolated position liq * another liquidation review * add test * cargo fmt -- * tweak naming * add test to make sure false liquidaiton wont be triggered * test meets withdraw * change is bankrupt * more * update uses of exit isolated liquidaiton * moar * moar * reduce diff * moar * modularize some for tests * add tests for the pnl for deposit liquidation * tests for isolated position transfer * test for update spot balance * test for settle pnl * add perp position max margin * program: test for custom perp position margin ratio * add test for margin calc for disable hlm * update test name * make max margin ratio persist * add liquidation mode test * more tests to make sure liqudiations dont bleed over * change test name * fix broken cargo tests * cargo fmt -- * first ts test * isolatedPositionLiquidatePerp test * isolatedPositionLiquidatePerpwithFill test * fix expired position * cargo fmt -- * feat: initial SDK Changes for iso pos * feat: margin calc unit tests * temp * feat: finally - parity with on-chain cargo test * fix: PR feedback and cleanup + decoding position flag wrong * feat: deposit into iso position ixs * temp: pr feedback nother round * feat: per perp pos max margin ratio * feat: additional ixs for transfer into iso + update perp margin ratio * feat: revamp liquidation checker functions for cross vs iso margin * fix: adjust health getter for user * fix: liq statuses add to return signature * chore: post rebase cleaner upper * fix: missing params from per market lev * feat: zero out account withdraw from perp position * fix: available positions logic update for iso * feat: iso position txs cleanup + ix ordering * feat: onchain props for signed msg orders + idl update * feat: cancels withdraw from iso pos * fix: only settle if needed iso withdraw + i64 min * feat: improvements to single grpc test * feat: buffer on margin deposits to avoid insuff collat err * feat: helpful scripts for testing/manipulating iso positions * chore: re organizing some user sdk funcs * fix: bug with max amount withdrawal for transfer iso perp * fix: post merge dupe field on swift * feat: min and max 64 constants * fix: bug with margin removal * fix: missing swift iso deposit from idl * fix: lint and prettify * feat: increased buffer on isolated deposit opening position * fix: missing check on order increasing size for depositing margin place + take * feat: settle pnl when trying to transfer to cross * fix: incorrect iso bankruptcy flag * feat: new margin calc logic * fix: broken test helpers * feat: buffer adjustments * fix: add missing swap ix update * fix: undefined this on isoalted free collateral * fix: prettier broke * fix: handle perp buying power on new iso position * fix: try/catch wrap on user isolated get free collat * feat: try settle flag for transfer to iso perp * fix: properly handle perp buying power existing iso position increase * feat: alpha npm version * fix: decoding isolated scaled balance incorrectly maybe * fix: build error rm lp field * feat: publish isPerpPositionIsolated as public method * sdk: add ix for token 2022 init account deposits (#2050) * add ix for token 2022 init account deposits * only call checkAccountExists if token2022 * update changelog * sdk: release v2.152.0-beta.3 * program: add bit_flags in preparation for iso pos (#2053) * program: add bit_flags in preparation for iso pos * CHANGELOG * program: base-spread-validate-buffer (#2052) * program: base-spread-validate-buffer * CHANGELOG --------- Co-authored-by: Chris Heaney <[email protected]> * v2.152.0 * ui: save titan tx when quoted and reuse on swap (#2055) * fix titan quoting for dsol * fix dsol instant unstake * feat: minified with esbuild (#2056) * feat: minified with esbuild * fix: rm webpack * fix: prettier titanClient * ui: fix falsely failing quotes from titan (#2058) * ui: fix falsely failing quotes from titan * prettify * check feed id after pyth pull atomic update * fix: many null checks fixed (#2059) * fix: many null checks fixed * fix: prettier * feat: get active markets helpers * fix: prettier * fix: README on margin calc was incorrect * fix: prettier and lint * fix: rm weird program diff * fix: rm weird program diff 2 * fix: rm weird empty file = * fix: rm useless diffs * refactor: remove unused fields a bunch on margin calc * fix: rebuild idl * fix: prevent unnecessary excpetion on liq price if free collat delta not computed * program: delete sereum/ob configs ix (#2066) * hot wallet update config stats * add delete for serum * delete ob config * CHANGELOG * sdk: release v2.153.0-beta.2 * Nick/external init account support (#2067) * wip: add external signer support for init account, stats account, swift account * updates * fix prettify * sdk: release v2.153.0-beta.3 * fix: user fastDecode check iso deposit and pos flag * fix: broken tests and PR cleanup * fix: final anchor tests fix? --------- Co-authored-by: Chris Heaney <[email protected]> Co-authored-by: lowkeynicc <[email protected]> Co-authored-by: GitHub Actions <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: bigz_Pubkey <[email protected]> Co-authored-by: wphan <[email protected]> Co-authored-by: chakos <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.